package com.ruoyi.st.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 票面价格对象 st_ticket_price
 * 
 * @author ruoyi
 * @date 2024-11-07
 */
public class StTicketPrice extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    private Long id;

    /** 票面类型 */
    @Excel(name = "票面类型")
    private String ticketType;

    /** 票价 */
    @Excel(name = "票价")
    private Integer ticketPrice;

    /** 有无货 */
    @Excel(name = "有无货")
    private String status;

    /** 票面状态 */
    @Excel(name = "票面状态")
    private Integer statusCode;

    /** 票数 */
    @Excel(name = "票数")
    private Integer quantity;

    /** ticket_date外键 */
    @Excel(name = "ticket_date外键")
    private Long ticketDateId;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setTicketType(String ticketType) 
    {
        this.ticketType = ticketType;
    }

    public String getTicketType() 
    {
        return ticketType;
    }
    public void setTicketPrice(Integer ticketPrice) 
    {
        this.ticketPrice = ticketPrice;
    }

    public Integer getTicketPrice() 
    {
        return ticketPrice;
    }
    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }
    public void setStatusCode(Integer statusCode) 
    {
        this.statusCode = statusCode;
    }

    public Integer getStatusCode() 
    {
        return statusCode;
    }
    public void setQuantity(Integer quantity) 
    {
        this.quantity = quantity;
    }

    public Integer getQuantity() 
    {
        return quantity;
    }
    public void setTicketDateId(Long ticketDateId) 
    {
        this.ticketDateId = ticketDateId;
    }

    public Long getTicketDateId() 
    {
        return ticketDateId;
    }

    @Override
    public String toString() {
        return str(new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId() + ",")
                .append("ticketType", getTicketType()+ ",")
                .append("ticketPrice", getTicketPrice()+ ",")
                .append("status", getStatus()+ ",")
                .append("statusCode", getStatusCode()+ ",")
                .append("quantity", getQuantity()+ ",")
                .append("ticketDateId", getTicketDateId())
                .toString());
    }
    private String str(String data){
        // 找到第一个 '[' 的位置
        int firstBracket = data.indexOf('[');
        // 找到第二个 '[' 的位置
        int secondBracket = data.indexOf('[',  1);

        // 拼接字符串，去掉第一个 '[' 和第二个 '[' 之间的内容
        String cleanedData = data.substring(0, 0) + data.substring(secondBracket);
        return cleanedData;
    }
}
